package base;

import java.util.Date;
import javafx.util.Pair;
import utils.Log;

public class CloneTest {


  public static void main(String[] args) throws CloneNotSupportedException {
    Base base = new Base(1, new Pair<>(2, 3));

    Log.vn(base.clone().toString());
    base.x = 4;
    Log.vn(base.clone().toString());

    Child child = new Child(5, new Pair(6, 7));
    child.b = true;
    Log.vn(child.clone().toString());

    Child copy = (Child)child.clone();
    copy.x = 88;
    copy.pair = new Pair<>(8, 0);
    Log.vn(child.toString());
    Log.vn(copy.toString());
  }
}
